import { createRouter, createWebHistory,createWebHashHistory } from 'vue-router'
import HomePage from './components/HomePage.vue'
import NodeList from './components/k8s/NodeList.vue'
import PodList from './components/k8s/workload/PodList.vue'
import DeploymentList from './components/k8s/workload/DeploymentList.vue'
import DaemonSetList from './components/k8s/workload/DaemonSetList.vue'
import StatefulSetList from './components/k8s/workload/StatefulSetList.vue'
import JobList from './components/k8s/workload/JobList.vue'
import CronJobList from './components/k8s/workload/CronJobList.vue'
import EventList from './components/k8s/EventList.vue'


import ConfigmapList from './components/k8s/config/ConfigmapList.vue'
import SecretList from './components/k8s/config/SecretList.vue'
import ResourceQuotaList from './components/k8s/config/ResourceQuotaList.vue'
import LimitRangeList from './components/k8s/config/LimitRangeList.vue'

import ServiceList from './components/k8s/network/ServiceList.vue'
import IngressList from './components/k8s/network/IngressList.vue'


import StorageClassList from './components/k8s/storage/StorageClassList.vue'

import PersistentVolumeList from './components/k8s/storage/PersistentVolumeList.vue'
import PersistentVolumeClaimList from './components/k8s/storage/PersistentVolumeClaimList.vue'


const routerHistory =createWebHashHistory()// createWebHistory()

const router = createRouter({
    history: routerHistory,
    routes: [
      {
        path: '/',
        component: HomePage,
        children: [
            {
              path: "/",redirect:"/NodeList"
            },
            {
              path: "/NodeList",
              component: NodeList
            },
            {
              path: "/PodList",
              component: PodList
            },
            {
              path: "/DeploymentList",
              component: DeploymentList
            },
            {
              path: "/DaemonSetList",
              component: DaemonSetList
            },
            {
              path: "/StatefulSetList",
              component: StatefulSetList
            },
            {
              path: "/JobList",
              component: JobList
            },
            {
              path: "/CronJobList",
              component: CronJobList
            },
            {
              path: "/EventList",
              component: EventList
            },
            {
              path: "/ConfigmapList",
              component: ConfigmapList
            },
            {
              path: "/SecretList",
              component: SecretList
            },
            {
              path: "/ResourceQuotaList",
              component: ResourceQuotaList
            },
            {
              path: "/ServiceList",
              component: ServiceList
            },
            {
              path: "/IngressList",
              component: IngressList
            },
            {
              path: "/StorageClassList",
              component: StorageClassList
            },
            {
              path: "/PersistentVolumeClaimList",
              component: PersistentVolumeClaimList
            },
            {
              path: "/PersistentVolumeList",
              component: PersistentVolumeList
            },
            {
              path: "/LimitRangeList",
              component: LimitRangeList
            },

            
            

            
            

            

            
        ]
      }
    ]
})
export default router
